//kZime
#include <cstdio>
#include <iostream>
#include <cstring>
#include <algorithm>
#include <cmath>
using namespace std;

inline void File_read() {
#ifndef MYLAB
	return;
#endif
	freopen("in.txt", "r", stdin);
}

class node {
public:
	double x, y;
}p[23333];

int n, cnt, top, stack_[23333];
double ans;

inline double get_lth(node a, node b) {
	double cx = abs(b.x - a.x);
	double cy = abs(b.y - a.y);
	double k = sqrt(cx * cx + cy * cy);
	return k;
}

inline bool check_(int fr ,int t1, int t2) {
	double a1 = p[t1].y - p[fr].y;
	double b1 = p[fr].x - p[t1].x;
	double a2 = p[t2].y - p[fr].y;
	double b2 = p[fr].x - p[t2].x;
    return a2 * b1 >= a1 * b2;
}

inline double get_db() {
	char a[100];
	a[0] = getchar();
	int len = 0;
	for(; !isdigit(a[len]); a[len] = getchar()) if (a[len] == '-') len++;
	for(; isdigit(a[len]) || a[len] == '.' ;a[len] = getchar()) len++;
	return atof(a);
}

inline bool cmp(const node a, const node b) {
	int m = p[1].x;
	int n = p[1].y;
	int x1 = a.x;
	int y1 = a.y;
	int x2 = b.x;
	int y2 = b.y;
	return (x1 - m) * (y2 - n) < (x2 - m) * (y1 - n);
}

int main() {
//	File_read();
	n = get_db();
	printf("%.2lf", n);
	for(int i = 1; i <= n; i++) {
		p[i].x = get_db();
		p[i].y = get_db();
	}
	int mx = 0x7fffffff;
	int my = 0x7fffffff;
	int begin = 0;
	for(int i = 1; i <= n; i++) {
		if(p[i].x < mx && p[i].y < my) {
			mx = p[i].x;
			my = p[i].y;
			begin = i;
		}
	}
	swap(p[1], p[begin]);
	
	sort(p + 2, p + n + 1, cmp);
	
	
	stack_[++top] = 1;
	stack_[++top] = 2;
	
    for(int i = 3; i <= n; i++){
        while(!check_(stack_[top - 1], stack_[top], i)) {
            stack_[top--] = 0;
        }
        stack_[++top] = i;
    }
    stack_[++top] = 1;
    
    
    
	for(int i = 2; i <= top; i++) {
    	ans += get_lth(p[stack_[i - 1]], p[stack_[i]]);
	}
    
    printf("%.2lf", ans);

}
